package org.cid54.bukkit.command;

/**
 *
 * @author fgo
 */
public class ParaboolCommand {

    /**
     * package jsphere;
    
    import java.awt.Color;
    import java.awt.Graphics2D;
    import java.awt.Image;
    import java.awt.image.BufferedImage;
    import java.awt.image.RenderedImage;
    import java.io.File;
    import java.io.IOException;
    import java.util.logging.Level;
    import java.util.logging.Logger;
    import javax.imageio.ImageIO;
    
    /**
     *
     * @author fgo
     */
    public class JSphere {
////    /**
////     * @param args the command line arguments
////     */
////    public static void main(String[] args) {
////
////        //(x/r)² + (z/r)² + 2y = 0
////        //(x/r)² + (z/r)² = -2y
////        //((x/r)² + (z/r)²)/(-2) = y
////
////        int h = 500;
////        int r = 4;
////
////        BufferedImage image = new BufferedImage(20 + h, h, BufferedImage.TYPE_3BYTE_BGR);
////
////        Graphics2D graf = image.createGraphics();
////
////        graf.setColor(Color.red);
////
////        graf.translate(h / 2, 0);
////
////        for (int x = -h; x <= h; x++) {
////            for (int z = -h; z <= h; z++) {
////
////                double y = ((x * x) + (z * z)) / (r * r * 2.0D);
////
////                if (y <= h) {
////
//////                    graf.setColor(new Color(100, 100, (int) y / 2));
//////
//////                    graf.drawRect(x, z, 1, 1);
////
////                    graf.drawRect(x, (int) y, 1, 1);
////
////                }
////
////            }
////        }
////
////        for (int y = 0; y <= h; y++) {
////            for (int z = -h; z <= h; z++) {
////
////                double x = Math.sqrt((2 * r * r * y) - (z * z));
////
////                if (Double.isNaN(x) && Double.isInfinite(x)) {
////
////                    graf.setColor(new Color(100, 100, (int) y / 2));
////
////                    graf.drawRect((int) x, y, 1, 1);
////
////                    graf.drawRect((int) (-1.0D * x), y, 1, 1);
////
////                }
////
////            }
////        }
////
////        for (int y = 0; y <= h; y++) {
////            for (int x = -h; x <= h; x++) {
////
////                double z = Math.sqrt((2 * r * r * y) - (x * x));
////
////                if (Double.isNaN(z) && Double.isInfinite(z)) {
//////                    graf.setColor(new Color(100, 100, (int) y / 2));
//////
//////                    graf.drawRect(x, (int) z, 1, 1);
//////                    graf.drawRect(x, (int) (-1.0D * z), 1, 1);
////                }
////
////            }
////        }
////
////        try {
////            ImageIO.write(image, "jpg", new File("C:/test.jpg"));
////        } catch (IOException ex) {
////            Logger.getLogger(JSphere.class.getName()).log(Level.SEVERE, null, ex);
////        }
////
////    }
////}
    }
}
